package com.kaifamiao.datatypes;

public class Loong {
    public static void main(String[] args) {

        // 以单个字符为字面量 (在单引号中指定单个字符)
        char first = '辣';
        System.out.println( first );

        // 以整数为字面量 (整数范围是 0 ~ 65535 )
        // char second = 0x8fa3;
        char second = 0b1000_1111_1010_0011;
        System.out.println( second );

        // 以转义字符为字面量 (在单引号中指定转义字符)
        // char third = '\n';
        char third = '\'';
        System.out.println( third );

        // 以Unicode编码为字面量 (在单引号中指定Unicode编码)
        char fourth = '\u9ebb';
        System.out.println( fourth );

    }
}
